<?php

namespace plugin\coupon\app\admin\controller;

use app\common\controller\BaseAdminController;
use plugin\coupon\app\admin\logic\CouponLogic;

/**
 * 卡券
 * Class CouponController
 * @package plugin\coupon\app\admin\controller
 */
class CouponController extends BaseAdminController
{
    protected function init()
    {
        parent::init();
        $this->logic = new CouponLogic();
    }

    protected function searchWhere()
    {
        $where = [];
        $this->form['name'] && $where[] = ['name', 'like', "%{$this->form['name']}%"];
        return $where;
    }
}
